// 把token加到User里的写法
// import { ApiProperty, PartialType } from '@nestjs/swagger';
// import { UserVo } from './list-user-vo';

// export class UserLoginVo extends PartialType(UserVo) {
//   @ApiProperty({ description: 'token', required: true })
//   token: string;
// }
import { ApiProperty } from '@nestjs/swagger';
export class UserVo {
  @ApiProperty({ description: 'id', required: false })
  id: number;

  @ApiProperty({ description: '账号', required: false })
  account: string;

  @ApiProperty({ description: '用户名', required: false })
  username: string;

  @ApiProperty({ description: '昵称', required: false })
  nickName: string;

  @ApiProperty({ description: '性别', required: false })
  gender: string;

  @ApiProperty({ description: '头像', required: false })
  avatarURL: string;

  @ApiProperty({ description: '邮件', required: false })
  email: string;

  @ApiProperty({ description: '手机号', required: false })
  phone: string;

  @ApiProperty({ description: '是否管理员', required: false })
  isAdmin: string;

  @ApiProperty({ description: '账号状态', required: false })
  status: string;

  @ApiProperty({ description: '权限', required: false })
  role: string;

  @ApiProperty({ description: '创建时间', required: false })
  createTime: Date;

  @ApiProperty({ description: '更新时间', required: false })
  updateTime: Date;
}
export class UserLoginVo {
  @ApiProperty({
    type: UserVo,
    description: '用户列表',
    required: false,
  })
  user: UserVo;

  @ApiProperty({ description: 'token', required: false })
  token: string;
}
